# Maintainer: Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>

pkgname=template-glib
pkgver=3.30.0
pkgrel=1
pkgdesc="A templating library for GLib"
url="https://gitlab.gnome.org/GNOME/template-glib"
arch=(x86_64)
license=(LGPL)
depends=(glib2 gobject-introspection-runtime)
makedepends=(git meson vala gobject-introspection gtk-doc)
_commit=3fe77c8d7028c0c72888a0857337facb3c533272  # tags/3.30.0^0
source=("git+https://gitlab.gnome.org/GNOME/template-glib.git#commit=$_commit")
sha256sums=('SKIP')

pkgver() {
  cd $pkgname
  git describe --tags | sed 's/-/+/g'
}

prepare() {
  cd $pkgname
}

build() {
  arch-meson $pkgname build -D enable_gtk_doc=true
  ninja -C build
}

check() {
  meson test -C build
}

package() {
  DESTDIR="$pkgdir" meson install -C build
}
